1. Field of the Invention
The present invention generally relates to data processing apparatus and, more particularly, is directed to an inner product calculating circuit suitable for use in a calculating circuit which calculates an inner product of a constant vector and an arbitrary input vector, for example.
2. Description of the Prior Art
While a product of a constant matrix and an arbitrary input vector must be calculated in a discrete cosine transform (DCT), a discrete Fourier transform (DFT) or the like (see Japanese Laid-Open Patent Publication No. 62-61159), a product of a constant matrix of m lines.times.m columns (m is an integer larger than 2) and an m-dimensional input vector, for example, can be obtained by calculating an inner product of m-dimensional constant vector and m-dimensional arbitrary vector m times. In general, an m-dimensional constant vector is represented as &lt;dj&gt; (j=0, 1, . . . ) and m elements of this constant vector are represented as dj,k (k=0, 1, . . . , m-1). Also, assuming that an m-dimensional arbitrary vector is represented as &lt;xj&gt; and that m elements of this arbitrary vector are represented as xj,k, then vectors &lt;dj&gt; and &lt;xj&gt; are expressed by the following equation (1): ##EQU1##
In this case, let us assume an inner product calculating circuit in which an inner product &lt;d0&gt;.multidot.&lt;x0&gt; is calculated at timing point t0, an inner product &lt;d1&gt;.multidot.&lt;xl&gt; is calculated at timing point t1 in the same manner and inner products &lt;dj&gt;.multidot.&lt;xj&gt; are sequentially calculated.
FIG. 1 shows a conventional inner product calculating circuit utilized for the above-mentioned purpose where m=8. In FIG. 1, reference symbols 1A through 1H depict the same multiplying units, respectively and these multiplying units 1A to 1H are respectively supplied with eight-dimensional arbitrary input vector elements I0 to I7. More specifically, the multiplying unit 1A is composed of a multiplier 2 and a coefficient memory 3 which sequentially supplies a first element of a series of constant vectors to one input portion of the multiplier 2. The multiplier 2 is supplied at the other input portion thereof with the first element I0 and the multiplier 2 derives at its output portion a product of the first element I0 and the element supplied thereto from the coefficient memory 3.
Similarly, the multiplying units 1B to 1H derive products of input vector elements and elements supplied thereto from the coefficient memories, and the calculated result, which is provided by adding the outputs of these multiplying units 1A to 1H by using adders 4A to 4G, is produced as the output of the whole inner product calculating circuit shown in FIG. 1. For example, assuming that the input elements I0 to I7 are eight elements of eight dimensional input vectors &lt;xj&gt; and that eight elements of the constant vector &lt;dj&gt; are supplied from the eight coefficient memories to the corresponding adders, then the inner product calculating circuit derives an output yj which is an inner product of the vector &lt;xj&gt; and the vector &lt;dj&gt;. Generally, when the inner product of the m-dimensional arbitrary vector and the m-dimensional constant vector is obtained by inputting all elements of the arbitrary vector in parallel with one another, then the conventional inner product calculating circuit needs m multipliers.
However, it is frequently observed that the kind of coefficients involved in the transform matrix is less than the number of lines or columns in the DCT calculation, the DFT calculation or the like and that the kind of the elements of the constant vector is less than the number of dimension accordingly. From this viewpoint, it can be expected that the number of multipliers used in the inner product calculating circuit which calculates the inner product of such constant vector and arbitrary vector can be reduced.